/*
 * irq.c
 *
 *  Created on: 2024年8月16日
 *      Author: nwz
 */

#include <all_header.h>

void HAL_UART_TxCpltCallback(UART_HandleTypeDef *huart) {
	if (huart == &huart1) {
		console_write_task_send_cmplt_callback(huart);
	}
}

void HAL_UART_RxCpltCallback(UART_HandleTypeDef *huart) {
	if (huart == &huart1) {
		console_read_task_dma_cmpt_callback();
	}
}

void HAL_UART_RxHalfCpltCallback(UART_HandleTypeDef *huart) {
	if (huart == &huart1) {
		console_read_task_dma_half_cmpt_callback();
	}
}

void HAL_UART_ReceiveTimeoutCallback(UART_HandleTypeDef *huart) {
	// receive time out
	if (huart == &huart1) {
		console_read_task_uart_timeout_callback();
	}

}

void HAL_SPI_TxCpltCallback(SPI_HandleTypeDef *hspi) {
	if (hspi == &hspi3) {

	}
}
